import { GSprite } from "../../../../../com/mui/controls/GSprite";
import { GCheckBox } from "../../../../../com/mui/controls/GCheckBox";
import { ObjCreate } from "../../common/ObjCreate";
import { ImagesConst } from "../../../resource/ImagesConst";
import { Language } from "../../../../../extend/language/Language";
import { Dispatcher } from "../../../../mvc/core/Dispatcher";
import { DataEvent } from "../../../events/DataEvent";
import { EventName } from "../../../mvc/EventName";
//class FashionOperaPanel
    
    export  class FashionOperaPanel extends GSprite
    {
        constructor()
        {
            super();
            this.init();
            return;
        }

        public get showWingCheckBox(): GCheckBox
        {
            return this._showWingCheckBox;
        }

        public get showFashWeaponCheckBox(): GCheckBox
        {
            return this._showFashWeaponCheckBox;
        }

        public get showFootPrintCheckBox(): GCheckBox
        {
            return this._showFootPrintCheckBox;
        }

        public get showBubbleCheckBox(): GCheckBox
        {
            return this._showBubbleCheckBox;
        }

        public get showSurroundCheckBox(): GCheckBox
        {
            return this._showSurroundCheckBox;
        }

        public get showWaistBeltCheckBox(): GCheckBox
        {
            return this._showWaistBeltCheckBox;
        }

        public get showElfCheckBox(): GCheckBox
        {
            return this._showElfCheckBox;
        }

        /* internal  */init(): void
        {
            ObjCreate.createBg(0, 0, 90, 175, this, ImagesConst.ToolTipBg);
            this._showWingCheckBox = ObjCreate.createCheckBox(Language.getString(30195), 10, 5, 80, 25, this, "GCheckBox");
            this._showWingCheckBox.buttonMode = true;
            this._showWingCheckBox.useHandCursor = true;
            this._showWingCheckBox.addEventListener(flash.events.MouseEvent.CLICK, this.onShowWingCbClickHandler);
            this._showFashionCheckBox = ObjCreate.createCheckBox(Language.getString(30269), 10, 25, 80, 25, this, "GCheckBox");
            this._showFashionCheckBox.buttonMode = true;
            this._showFashionCheckBox.useHandCursor = true;
            this._showFashionCheckBox.addEventListener(flash.events.MouseEvent.CLICK, this.onShowFashionCbClickHandler);
            this._showFashWeaponCheckBox = ObjCreate.createCheckBox(Language.getString(30270), 10, 45, 80, 25, this, "GCheckBox");
            this._showFashWeaponCheckBox.buttonMode = true;
            this._showFashWeaponCheckBox.useHandCursor = true;
            this._showFashWeaponCheckBox.addEventListener(flash.events.MouseEvent.CLICK, this.onShowFashWeaponCbClickHandler);
            this._showFootPrintCheckBox = ObjCreate.createCheckBox(Language.getString(30311), 10, 65, 80, 25, this, "GCheckBox");
            this._showFootPrintCheckBox.buttonMode = true;
            this._showFootPrintCheckBox.useHandCursor = true;
            this._showFootPrintCheckBox.addEventListener(flash.events.MouseEvent.CLICK, this.onShowFootPrintCbClickHandler);
            this._showBubbleCheckBox = ObjCreate.createCheckBox(Language.getString(71444), 10, 85, 80, 25, this, "GCheckBox");
            this._showBubbleCheckBox.buttonMode = true;
            this._showBubbleCheckBox.useHandCursor = true;
            this._showBubbleCheckBox.addEventListener(flash.events.MouseEvent.CLICK, this.onShowBubbleCbClickHandler);
            this._showSurroundCheckBox = ObjCreate.createCheckBox(Language.getString(71461), 10, 105, 80, 25, this, "GCheckBox");
            this._showSurroundCheckBox.buttonMode = true;
            this._showSurroundCheckBox.useHandCursor = true;
            this._showSurroundCheckBox.addEventListener(flash.events.MouseEvent.CLICK, this.onShowSurroundCbClickHandler);
            this._showWaistBeltCheckBox = ObjCreate.createCheckBox(Language.getString(71480), 10, 125, 80, 25, this, "GCheckBox");
            this._showWaistBeltCheckBox.buttonMode = true;
            this._showWaistBeltCheckBox.useHandCursor = true;
            this._showWaistBeltCheckBox.addEventListener(flash.events.MouseEvent.CLICK, this.onShowWaistBeltCbClickHandler);
            this._showElfCheckBox = ObjCreate.createCheckBox(Language.getString(71482), 10, 145, 80, 25, this, "GCheckBox");
            this._showElfCheckBox.buttonMode = true;
            this._showElfCheckBox.useHandCursor = true;
            this._showElfCheckBox.addEventListener(flash.events.MouseEvent.CLICK, this.onShowElfCbClickHandler);
            return;
        }

        /* internal  */onShowWingCbClickHandler(arg1: Object /* flash.events.MouseEvent */): void
        {
            this._showWing = !this._showWingCheckBox.selected;
            Dispatcher.dispatchEvent(new DataEvent(EventName.PlayerSetIsNotShowWing, this._showWing));
            return;
        }

        /* internal  */onShowFashionCbClickHandler(arg1: Object /* flash.events.MouseEvent */): void
        {
            this._showFation = !this._showFashionCheckBox.selected;
            Dispatcher.dispatchEvent(new DataEvent(EventName.PlayerSetIsNotShowFashion, this._showFation));
            return;
        }

        /* internal  */onShowFashWeaponCbClickHandler(arg1: Object /* flash.events.MouseEvent */): void
        {
            this._showFashWeapon = !this._showFashWeaponCheckBox.selected;
            Dispatcher.dispatchEvent(new DataEvent(EventName.PlayerSetIsNotShowFashionWeapon, this._showFashWeapon));
            return;
        }

        /* internal  */onShowFootPrintCbClickHandler(arg1: Object /* flash.events.MouseEvent */): void
        {
            this._showFootPrint = !this._showFootPrintCheckBox.selected;
            Dispatcher.dispatchEvent(new DataEvent(EventName.PlayerSetIsNotShowFootPrint, this._showFootPrint));
            return;
        }

        protected onShowBubbleCbClickHandler(arg1: Object /* flash.events.MouseEvent */): void
        {
            this._showBubble = !this._showBubbleCheckBox.selected;
            Dispatcher.dispatchEvent(new DataEvent(EventName.PlayerSetIsNotShowBubble, this._showBubble));
            return;
        }

        protected onShowSurroundCbClickHandler(arg1: Object /* flash.events.MouseEvent */): void
        {
            this._showSurround = !this._showSurroundCheckBox.selected;
            Dispatcher.dispatchEvent(new DataEvent(EventName.PlayerSetIsNotShowSurround, this._showSurround));
            return;
        }

        /* internal  */onShowWaistBeltCbClickHandler(arg1: Object /* flash.events.MouseEvent */): void
        {
            this._showWaistBelt = !this._showWaistBeltCheckBox.selected;
            Dispatcher.dispatchEvent(new DataEvent(EventName.PlayerSetIsNotShowWaistBelt, this._showWaistBelt));
            return;
        }

        /* internal  */onShowElfCbClickHandler(arg1: Object /* flash.events.MouseEvent */): void
        {
            this._showElf = !this._showElfCheckBox.selected;
            Dispatcher.dispatchEvent(new DataEvent(EventName.PlayerSetIsNotShowElf, this._showElf));
            return;
        }

        public get showFashionCheckBox(): GCheckBox
        {
            return this._showFashionCheckBox;
        }

        /* internal */ /* var */_showFation: Boolean;

        /* internal */ /* var */_showWing: Boolean;

        /* internal */ /* var */_showFashWeapon: Boolean;

        /* internal */ /* var */_showFootPrint: Boolean;

        /* internal */ /* var */_showBubble: Boolean;

        /* internal */ /* var */_showSurround: Boolean;

        /* internal */ /* var */_showWaistBelt: Boolean;

        /* internal */ /* var */_showElf: Boolean;

        /* internal */ /* var */_showFashionCheckBox: GCheckBox;

        /* internal */ /* var */_showWingCheckBox: GCheckBox;

        /* internal */ /* var */_showFashWeaponCheckBox: GCheckBox;

        /* internal */ /* var */_showFootPrintCheckBox: GCheckBox;

        /* internal */ /* var */_showBubbleCheckBox: GCheckBox;

        /* internal */ /* var */_showSurroundCheckBox: GCheckBox;

        /* internal */ /* var */_showWaistBeltCheckBox: GCheckBox;

        /* internal */ /* var */_showElfCheckBox: GCheckBox;
    }
